Network connection apparatus, connection system, and network connection method

ABSTRACT

A system for connecting networks that can automatically avoid address clashes to maintain communication in inter-network communication, which includes a storage unit for storing a table, a comparison unit for comparing an interface address which has been set up in a first interface with a second interface address which is set up in a second interface, a network suspension unit for, in response to address clash of the addresses compared by the comparison unit, suspending connection between the second network and an apparatus for connecting networks, a readout unit for reading out addresses including a first interface address which is different from the second interface address out of the table stored in the storage unit, and an address change unit for changing the interface address which has been set up in the first interface to the first interface address included in the addresses read out by the readout unit.

TECHNICAL FIELD

The present invention relates to network communication, in particular,to an apparatus and system for connecting networks, and a method forconnecting networks, which can avoid address clashes in inter-networkcommunication.

BACKGROUND ART

In network communication, a comparatively small-sized network sometimesmakes a connection to a large-sized network dynamically using anapparatus for connecting networks such as a gateway so as tosend/receive data to/from the large-sized network.

For example, the dynamic connection to a network corresponds to a caseof making a connection to a network provided by an ISP (Internet ServiceProvider) through a dial-up router from a home-LAN (Local Area Network).The user has an access to an ISP from a PC (Personal Computer)configuring a home-LAN through dial-up accessing. Then, the ISPallocates an IP (Internet Protocol) address to the PC. Thus, thehome-LAN and a network provided by the ISP is connected through adial-up router working as a gateway. The IP address allocated to the PCby the ISP is changed every time dial-up accessing is made.

In network communication, IP addresses of respective hosts existing in anetwork, which specify communication partners, have to be different fromeach other, and global IP addresses being unique IP addresses are givento respective hosts on a network under management of the NIC (NetworkInformation Center) and JPNIC (JP-Network Information Center).

A closed network such as a home-LAN or a firm-LAN is not subject to therule, and independent IP addresses can be set up so long as overlappedaddresses are not used in the closed network. In such a LAN, private IPaddresses, which are not permitted on the Internet, can be used. In casea private IP address is sent onto the Internet, its packet is deletedsince there is made a stipulation that such a private IP address mustnot be routed.

In a firm, as described above, a LAN may be configured using private IPaddresses, and, for example, a main office and its branch offices mayindependently configure a LAN respectively.

When performing network communication by connecting LANs that areindependently configured using private IP addresses, there occurs noproblem in case respective used address spaces are different from eachother. On the other hand, in case respective used address spaces areoverlapped, hosts of the same address undesirably exist in respectivenetworks, which disallows communication through a gateway.

In case there exist hosts of the same address, a private IP address of ahost belonging to one of networks has to be set up manually, whichrequires troublesome work.

It is anticipated that private IP addresses will further be used by anISP (Internet Service Provider) so as to avoid risks due to full-timeconnection, or owing to depletion of finite IP addresses. Thus, asdescribed above, when making a connection between different networks,there often occur address overlaps, which undesirably leads to delayedcommunication between networks.

DISCLOSURE OF THE INVENTION

Accordingly, the present invention has an object to overcome theabove-mentioned drawbacks of the prior art by providing a new apparatusand system for connecting networks, and a new method for connectingnetworks.

Furthermore, the present invention has another object to provide anapparatus and system for connecting networks, and a method forconnecting networks, which can automatically avoid address clashes incommunication between networks so as to maintain inter-networkcommunication.

The above object can be attained by providing an apparatus forconnecting networks which connects a first network, to which a pluralityof terminal units belong, and a second network through a first interfaceand a second interface, including:

storage means for storing a table having arranged therein a plurality ofaddresses consisting of a first interface address and a plurality ofterminal unit addresses which specify presences of the first interfaceand of the plural terminal units in the first network, and can be set upin the first interface and in the plural terminal units, respectively;

comparison means for, in response to connection between the secondnetwork and the apparatus for connecting networks after a secondinterface address which specifies presence of the second interface inthe second network is set up in the second interface, comparing aninterface address which has been set up in the first interface with thesecond interface address which is set up in the second interface;

network suspension means for, in response to address clash of theinterface address which has been set up in the first interface and thesecond interface address which is set up in the second interface aftercomparison by the comparison means, suspending connection between thesecond network and the apparatus for connecting networks;

readout means for, in response to suspension of the second network fromthe apparatus for connecting networks by the network suspension means,reading out addresses including a first interface address which isdifferent from the second interface address out of the table stored inthe storage means;

address change means for changing the interface address which has beenset up in the first interface to the first interface address included inthe addresses read out by the readout means;

first transmission means for sending an address change message that theinterface address which has been set up in the first interface ischanged to the first interface address by the address change means tothe plural terminal units;

reception means for, in response to change of terminal unit addresses ofthe plural terminal units by the terminal units after receiving theaddress change message sent from the first transmission means, receivingaddress change confirmation messages that the terminal unit addresses ofthe plural terminal units are changed which are sent from the respectiveterminal units; and

second transmission means for, in response to reception of the addresschange confirmation messages sent from the plural terminal units by thereception means, sending an address change end message that the entireterminal unit addresses of the plural terminal units are changed to theplural terminal units.

Also the above object can be attained by providing a system forconnecting networks which has an apparatus for connecting networks whichconnects a first network and a second network through a first interfaceand a second interface, and a plurality of terminal units which belongto the first network,

the apparatus for connecting networks including:

first storage means for storing a first table having arranged therein aplurality of addresses consisting of a first interface address and aplurality of terminal unit addresses which specify presences of thefirst interface and of the plural terminal units in the first network,and can be set up in the first interface and in the plural terminalunits, respectively;

address comparison means for, in response to connection between thesecond network and the apparatus for connecting networks after a secondinterface address which specifies presence of the second interface inthe second network is set up in the second interface, comparing aninterface address which has been set up in the first interface with thesecond interface address which is set up in the second interface;

network suspension means for, in response to address clash of theinterface address which has been set up in the first interface and thesecond interface address which is set up in the second interface aftercomparison by the address comparison means, suspending connectionbetween the second network and the apparatus for connecting networks;

readout means for, in response to suspension of the second network fromthe apparatus for connecting networks by the network suspension means,reading out addresses including a first interface address which isdifferent from the second interface address which is set up in thesecond interface out of the first table stored in the first storagemeans;

first address change means for changing the interface address which hasbeen set up in the first interface to the first interface addressincluded in the addresses read out by the readout means;

first transmission means for sending an address change message that theinterface address which has been set up in the first interface ischanged to the first interface address by the address change means tothe plural terminal units;

first reception means for receiving address change confirmation messagesthat the terminal unit addresses of the plural terminal units arechanged which are sent from the respective terminal units; and

second transmission means for, in response to reception of the addresschange confirmation messages sent from the plural terminal units by thefirst reception means, sending an address change end message that theentire terminal unit addresses of the plural terminal units are changedto the plural terminal units,

and each of the terminal units including:

second reception means for receiving the address change message sentfrom the first transmission means of the apparatus for connectingnetworks;

second address change means for, in response to reception of the addresschange message by the second reception means, changing an address of theterminal unit to the terminal unit address;

third transmission means for sending the address change confirmationmessage that the terminal unit address is changed by the second addresschange means to the apparatus for connecting networks; and

third reception means for receiving the address change end message sentfrom the second transmission means of the apparatus for connectingnetworks.

Also the above object can be attained by providing a method forconnecting networks for a system for connecting networks which has anapparatus for connecting networks which connects a first network and asecond network through a first interface and a second interface, and aplurality of terminal units which belong to the first network,

including the steps, by the apparatus for connecting networks, of:

storing a first table having arranged therein a plurality of addressesconsisting of a first interface address and a plurality of terminal unitaddresses which specify presences of the first interface and of theplural terminal units in the first network, and can be set up in thefirst interface and in the plural terminal units, respectively, in afirst storage means;

in response to connection between the second network and the apparatusfor connecting networks after a second interface address which specifiespresence of the second interface in the second network is set up in thesecond interface, comparing an interface address which has been set upin the first interface with the second interface address which is set upin the second interface;

in response to address clash of the interface address which has been setup in the first interface and the second interface address which is setup in the second interface after comparison in the comparison step,suspending connection between the second network and the apparatus forconnecting networks;

in response to suspension of the second network from the apparatus forconnecting networks, reading out addresses including a first interfaceaddress which is different from the second interface address which isset up in the second interface out of the first table stored in thefirst storage means;

changing the interface address which has been set up in the firstinterface to the first interface address included in the read outaddresses; and

sending an address change message that the interface address which hasbeen set up in the first interface is changed to the first interfaceaddress to the plural terminal units,

and including the steps, by each of the terminal units, of:

receiving the address change message sent from the apparatus forconnecting networks;

in response to reception of the address change message, changing anaddress of the terminal unit to the terminal unit address; and

sending an address change confirmation message that the terminal unitaddress is changed to the apparatus for connecting networks,

and including the steps, by the apparatus for connecting networks, of:

receiving the address change confirmation messages which are sent fromthe respective terminal units; and

in response to reception of the address change confirmation messagessent from the plural terminal units, sending an address change endmessage that the entire terminal unit addresses of the plural terminalunits are changed to the plural terminal units,

and including the step, by each of the terminal units, of:

receiving the address change end message sent from the apparatus forconnecting networks.

These objects and other objects, features and advantages of the presentinvention will become more apparent from the following detaileddescription of the preferred embodiments of the present invention.

BRIEF DESCRIPTION OF THE DRAWINGS

FIG. 1 shows a schematic view of a system for connecting networks.

FIG. 2 shows a schematic view of a gateway that connects networks in thesystem for connecting networks.

FIG. 3 shows a table of the gateway in the system for connectingnetworks.

FIG. 4 shows a table of a terminal unit in the system for connectingnetworks.

FIG. 5 shows a flow chart for explaining the operation of the gatewaywhen addresses clash in the system for connecting networks.

FIG. 6 shows a flow chart for explaining the operation of the terminalunit when addresses clash in the system for connecting networks.

BEST MODE FOR CARRYING OUT THE INVENTION

The apparatus and system for connecting networks, and the method forconnecting networks according to the present invention will further bedescribed below concerning the best modes for carrying out the presentinvention with reference to the accompanying drawings.

FIG. 1 shows a schematic view of a system for connecting networks towhich the present invention is adapted.

In the system for connecting networks to which the present invention isadapted, a network A which has a plurality of terminal units 10 n (“n”being natural number) connected thereon by the Ethernet (registeredtrademark), etc. to configure a LAN (Local Area Network) and a network Bwhich is an external network of the network A is connected by a gateway1 working as an apparatus for connecting networks, as shown in FIG. 1.

The network B is provided with a DHCP (Dynamic Host ConfigurationProtocol) server, not shown. The DHCP server is a server that canautomatically allocate IP addresses to respective hosts on a network.Being provided with the DHCP server, it becomes unnecessary for themanager to allocate IP addresses to PCs that are to be newly added ontoa network, and the host side does not have to set up an obtained IPaddress manually.

The DHCP server on the network B broadcasts an IP address to aninterface (iface) B1, to be described later, of the gateway 1 inresponse to a requirement from the network A. In this case, theinterface B1 becomes a client for the DHCP server.

Both the network A and the network B are closed network spaces, andprivate IP addresses are set up for the terminal units 10 n of thenetwork A and for hosts constituting the network B, respectively. Thatis, an address of the interface (iface) B1 is given dynamically by thenetwork B to which the interface B1 is connected.

The network connected to the gateway 1 is not restricted to the specificnetwork B alone, and may be a network B′ different from the network B.That is, the network B, which is connected to the interface (iface) B1,can be changed to the network B′.

FIG. 2 shows a schematic view of the gateway 1.

The gateway 1 includes an interface (iface) A1 for making a connectionto the network A, the interface (iface) B1 for making a connection tothe network B, an address clash detection unit 2, an address clashavoidance processing unit 3, a routing table flight data base 4, anaddress index correspondence data base 5, and a network A terminaladdress data base 6.

The interface A1 is an interface for making a connection to the networkA, in which a private IP address is set up.

The interface B1 is an interface for making a connection to the networkB, in which a private IP address is set up by the DHCP server, notshown.

For example, when making a connection to the network B, the gateway 1broadcasts a packet to confirm whether or not the DHCP server isprovided on the network B. Accordingly, the DHCP server on the network Bdetermines a predetermined private IP, and sends thus determined privateIP to the interface B1. Thus, a private IP address is set up in theinterface B1.

When a private IP address is set up in the interface B 1, the addressclash detection unit 2 compares thus set up private IP address with aprivate IP address of the interface A1 to judge whether or not the twoaddresses clash, that is, whether or not network addresses of thoseprivate IP addresses coincide with each other. When address clash isdetected, this information is sent to the address clash avoidanceprocessing unit 3. In case subnets are defined, subnet addresses arecompared to detect address clash.

When receiving information that address clash of the private IPaddresses of the interface A1 and interface B1 is detected at theaddress clash detection unit 2, the address clash avoidance processingunit 3 controls respective units overall so as to avoid address clash.

For example, in response to detection of address clash of the private IPaddresses, the address clash avoidance processing unit 3 suspendscommunication of the interface B1, and stores a routing table being heldconcerning the interface A1 and interface B1 in the routing table flightdata base 4.

Furthermore, in response to detection of address clash of the private IPaddresses, the address clash avoidance processing unit 3 changes anaddress index, and obtains new private IP addresses for the interface A1and for the terminal units 10 n from the address index correspondencedata base 5, to be described later, and sets up the private IPaddresses, respectively.

In response to detection of address clash of the private IP addresses ofthe interface A1 and interface B1, the routing table flight data base 4stores the routing table concerning the interface A1 and interface B1which is eliminated under the control of the address clash avoidanceprocessing unit 3. The routing table that is eliminated to be stored inthe routing table flight data base 4 is read out when new private IPaddresses are set up for the interface A1 and for the terminal units 10n, and is updated using the new private IP addresses.

The address index correspondence data base 5 is a data base having atable in which address indexes (addridx) correspond to addresses of theinterface A1 and of the terminal units 10 n.

For example, the address index correspondence data base 5 has storedtherein an interface address correspondence table, as shown in FIG. 3.In case an address index is “0”, “192.168.10.1” is set up as an IPaddress for the interface A1, and IP addresses in the range of“192.168.10.16” to “192.168.10.32” can be set up as IP addresses for theterminal units 10 n belonging to the network A. Similarly, in case anaddress index is “1”, “172.20.10.1” is set up as an IP address for theinterface A1, and IP addresses in the range of “172.20.10.16” to“172.20.10.32” can be set up as IP addresses for the terminal units 10 nbelonging to the network A.

Thus, IP addresses of the interface A1 and of the terminal units 10 nbelonging to the network A can be changed depending on the addressindex.

The network A terminal address data base 6 has stored therein private IPaddresses of the terminal units 10 n connected to the network A.

The gateway 1 may be provided with a DHCP server, not shown.Accordingly, the gateway 1 can give IP addresses dynamically in responseto requirements of the terminal units 10 n.

For example, each of the terminal units 10 n is a PC (Personal Computer)having function of network connection. The terminal units 10 n areconnected to the interface A1 of the gateway 1, and are connected to thenetwork B through the interface B1 of the gateway 1.

Each of the terminal units 10 n has a storage unit, not shown, havingstored therein a terminal unit address correspondence table in which IPaddresses corresponding to address indexes are written, as shown in FIG.4.

The terminal unit address correspondence table is a table correspondingto address indexes which are changed by the address clash avoidanceprocessing unit 3 in response to detection of address clash of theprivate IP addresses of the interface A1 and interface B1, and privateIP address of the terminal unit 10 n is changed when the address indexis changed.

For example, in case an address index is “0”, “192.168.10.24” is set upas a private IP address for the terminal unit 10 n, and in case anaddress index is “1”, “172.20.10.24” is set up as a private IP addressfor the terminal unit 10 n, as shown in FIG. 4.

The terminal unit 10 n receives information to change address index sentfrom the gateway 1, and changes its private IP address by referring tothe table shown in FIG. 4.

The terminal unit address correspondence table shown in FIG. 4 isunnecessary in case the gateway 1 is provided with the DHCP server andthe terminal units 10 n can automatically obtain IP addresses.

FIG. 5 shows a flow chart for explaining the operation of the gateway 1.

When there is raised a requirement to have an access to the network Bfrom a predetermined terminal unit 10 n belonging to the network A, theDHCP server of the network B selects a predetermined private IP address,and sets up thus selected private IP address in the interface B1. Thus,the network A and the network B are connected through the interface B1.

In step S1, after being connected to the network B, the address clashdetection unit 2 compares the private IP address set up in the interfaceB1 with a private IP address of the interface A1 to judge whether or notthose private IP addresses coincide with each other. In case thoseprivate IP addresses clash, the processing proceeds to step S2, and incase not, communication with the network B is initiated.

In step S2, the address clash avoidance processing unit 3 suspendscommunication with the network B through the interface B1, and deletesthe entire routing table which is a table relating IP addresses of hostson the network B with routing directions. In general, a router or agateway having routing function determines routing of packets using therouting table.

In step S3, the address clash avoidance processing unit 3 changes thecurrent address index (addridx) to a new unused address index.

For example, when a new address index is defined as “tmpaddridx” and aprevious address index is defined as “addridx”, the current addressindex can be changed to a new address index by performing calculationusing the following equation (1).tmpaddridx=1−addridx  (1)

When the current address index is “0”, a new address index becomes “1”from the equation (1).

In step S4, the address clash avoidance processing unit 3 obtainsaddresses for the entire terminal units 10 n belonging to the network A.In obtaining addresses, there are a manner in which the address clashavoidance processing unit 3 has an access to the network A terminaladdress data base 6 being a data base which has stored therein addressinformation of the entire terminal units 10 n belonging to the networkA, and a manner in which the address clash avoidance processing unit 3broadcasts packets for obtaining addresses to the terminal units 10 nbelonging to the network A and receives IP addresses sent accordinglyfrom the terminal units 10 n.

These manners of obtaining addresses depend on the configuration of thegateway 1, and whichever method can be employed in step S4.

In step S5, the address clash avoidance processing unit 3 sendsinformation that addresses of the interface A1 and interface B1 clash tothe entire terminal units 10 n belonging to the network A through theinterface A1, and broadcasts an address clash notice message including anew address index.

In step S6, the address clash avoidance processing unit 3 has an accessto the address index correspondence data base 5 to refer to theinterface address correspondence table shown in FIG. 3, and reads out aprivate IP address corresponding to a new address index calculated instep S3 using the equation (1), and then changes the private IP addressof the interface A1.

In step S7, the address clash avoidance processing unit 3 broadcastspredetermined packets to the entire terminal units 10 n belonging to thenetwork A, and confirms whether or not communication is possibledepending on responses for the packets.

In step S8, the address clash avoidance processing unit 3 judges whetheror not confirmation responses for the packets broadcasted in step S7 arereturned from the entire terminal units 10 n within a predetermined timeperiod. In case confirmation responses are returned from the entireterminal units 10 n within a predetermined time period, the processingproceeds to step S10, and in case not, the processing proceeds to stepS9.

In step S9, the address clash avoidance processing unit 3 restores theIP address of the interface A1 to the IP address corresponding to theaddress index which has not been changed yet in step S3. When theprocessing of step S9 comes to an end, the processing returns to stepS5, and the address clash notice message is broadcasted again to theterminal units 10 n.

In step S10, the address clash avoidance processing unit 3 refers to theinterface address correspondence table shown in FIG. 3 stored in theaddress index correspondence data base 5, and saves IP addresses of therespective terminal units 10 n corresponding to the new address index tothe network A terminal address data base 6 as the current IP addresses.Then, the address clash avoidance processing unit 3 sends an addresschange end message that the processing of changing private IP addressesof the interface A1 and of the terminal units 10 n is completed to theentire terminal units 10 n.

Thus, in response to address clash of the private IP addresses of theinterface A1 and interface B1, the gateway 1 changes the IP address ofthe interface A1 using the interface address correspondence table shownin FIG. 3, and broadcasts this information to the entire terminal units10 n belonging to the network A.

FIG. 6 shows a flow chart for explaining the operation of the terminalunit 10 n corresponding to the processing of the gateway 1 explainedusing FIG. 5.

In step S11, a control unit, not shown, of the terminal unit 10 nreceives the address clash notice message including a new address index(newaddridx) calculated in step S3 of the flow chart shown in FIG. 5,which is sent from the gateway 1.

In step S12, the unshown control unit changes the private IP address ofthe terminal unit 10 n using a new address index included in the addressclash notice message received in step S11 and the terminal unit addresscorrespondence table shown in FIG. 4 stored in a data base, not shown,of the terminal unit 10 n.

In case the gateway 1 is provided with the DHCP server and an IP addresscan be obtained from the gateway 1, after receiving the address clashnotice message, the private IP address set up in the terminal unit 10 nis deleted, and a new IP address is obtained by having an access to theDHCP server of the gateway 1.

In step S13, the terminal unit 10 n comes into the state of waiting anaddress change confirmation message broadcasted by the gateway 1 in stepS7 of the flow chart shown in FIG. 5.

In step S14, the unshown control unit judges whether or not the addresschange confirmation message sent from the gateway 1 is received within apredetermined time period. In case the address change confirmationmessage is received within a predetermined time period, the processingproceeds to step S15, and in case not, the processing proceeds to stepS19.

In step S15, the unshown control unit sends a response message to thegateway 1 in response to reception of the address change confirmationmessage.

In step S16, the unshown control unit comes into the state of waitingthe address change end message to be sent from the gateway 1.

In step S17, the unshown control unit judges whether or not the addresschange end message sent from the gateway 1 is received within apredetermined time period. In case the address change end message isreceived within a predetermined time period, the processing proceeds tostep S18, and in case not, the processing proceeds to step S19.

In step S18, in response to reception of the address change end message,the unshown control unit judges that the address change processing ofthe entire terminal units 10 n belonging to the network A issuccessfully performed, and changes the address index (addridx) storedin the storage unit, not shown, to a new address index (newaddridx) tosave thus changed address index.

In step S19, in response to failure of reception of the address changeend message, the unshown control unit judges that the address changeprocessing of another terminal unit 10 n belonging to the network A isunsuccessfully performed, and restores the private IP address of theterminal unit 10 n to the IP address before the change processing.

Thus, in response to reception of the address clash notice message sentfrom the gateway 1, the terminal unit 10 n can change its private IPaddress along with the change processing of the private IP address ofthe interface A1.

Thus, in response to address clash of the private IP addresses of theinterface A1 and interface B1, a private IP address of the interface A1of the gateway 1 is changed based on the interface addresscorrespondence table stored in the address index correspondence database 5, and accordingly a private IP address of the terminal unit 10 nis changed, which can automatically avoid address clashes.

In the above-described embodiments, the gateway 1 connects two networksor the network A and network B. On the other hand, the present inventionis not restricted to this, and the gateway 1 may connects a plurality ofnetworks more than two.

INDUSTRIAL APPLICABILITY

As in the above, according to the apparatus for connecting networks ofthe present invention, when addresses of network connection interfacesof a first network, to which a plurality of terminal units belong, and asecond network which is connected to the first network through theapparatus for connecting networks clash, a comparison unit immediatelydetects the address clash, and a network suspension unit suspendsconnection between the connected networks, which can avoid addressclash.

Next, the apparatus for connecting networks reads out a first interfaceaddress which does not clash out of a table stored in a storage unit,and changes an interface address of a first interface of the apparatusfor connecting networks by a first address change unit to connectnetworks, and accordingly changes terminal unit addresses of the pluralterminal units belonging to the first network by a second address changeunit. Thus, when address clash occurs in communication between networks,new addresses are automatically set up, maintaining communication.

As in the above, according to the system for connecting networks of thepresent invention, when addresses of network connection interfaces of afirst network, to which a plurality of terminal units belong, and asecond network which is connected to the first network through theapparatus for connecting networks clash, a comparison unit immediatelydetects the address clash, and a network suspension unit suspendsconnection between the connected networks, which can avoid addressclash.

Next, the system for connecting networks reads out a first interfaceaddress which does not clash out of a first table stored in a firststorage unit, and changes an interface address of a first interface ofthe apparatus for connecting networks by a first address change unit toconnect networks, and accordingly changes terminal unit addresses of theplural terminal units belonging to the first network by a second addresschange unit. Thus, when address clash occurs in communication betweennetworks, new addresses are automatically set up, maintainingcommunication.

As in the above, according to the method for connecting networks of thepresent invention, when addresses of network connection interfaces of afirst network, to which a plurality of terminal units belong, and asecond network which is connected to the first network through theapparatus for connecting networks clash, the address clash isimmediately detected, and connection between the connected networks issuspended, which can avoid address clash.

Next, a first interface address which does not clash is read out from afirst table stored in a first storage unit, and an interface address ofa first interface of the apparatus for connecting networks is changed tothe first interface address to connect networks, and accordinglyterminal unit addresses of the plural terminal units are changed. Thus,when address clash occurs in communication between networks, newaddresses are automatically set up, maintaining communication.

1. An apparatus for connecting networks which connects a first network,which includes a plurality of terminal units, and a second networkthrough a first interface and a second interface, comprising: storagemeans for storing a table having arranged therein a plurality ofaddresses consisting of a first interface address and a plurality ofterminal unit addresses which specify presences of the first interfaceand of the plural terminal units in the first network, and can be set upin the first interface and in the plural terminal units, respectively;comparison means for, in response to connection between the secondnetwork and the apparatus for connecting networks after a secondinterface address which specifies presence of the second interface inthe second network is set up in the second interface, comparing aninterface address which has been set up in the first interface with thesecond interface address which is set up in the second interface;network suspension means for, in response to address clash of theinterface address which has been set up in the first interface and thesecond interface address which is set up in the second interface aftercomparison by the comparison means, suspending connection between thesecond network and the apparatus for connecting networks; readout meansfor, in response to suspension of the second network from the apparatusfor connecting networks by the network suspension means, reading outaddresses including a first interface address which is different fromthe second interface address out of the table stored in the storagemeans; address change means for changing the interface address which hasbeen set up in the first interface to the first interface addressincluded in the addresses read out by the readout means; firsttransmission means for sending an address change message that theinterface address which has been set up in the first interface ischanged to the first interface address by the address change means tothe plural terminal units; reception means for, in response to change ofterminal unit addresses of the plural terminal units by the terminalunits after receiving the address change message sent from the firsttransmission means, receiving address change confirmation messages thatthe terminal unit addresses of the plural terminal units are changedwhich are sent from the respective terminal units; second transmissionmeans for, in response to reception of the address change confirmationmessages sent from the plural terminal units by the reception means,sending an address change end message that the entire terminal unitaddresses of the plural terminal units are changed to the pluralterminal units; second reception means for, in response to transmissionof the address change message by the first transmission means, receivingterminal unit address transmission requirements which are sent from theterminal units; and third transmission means for, in response to theterminal unit address transmission requirements received by the secondreception means, sending the terminal unit addresses included in theaddresses read out by the readout means out of the table stored in thestorage means to the respective plural terminal units included in thefirst network.
 2. The apparatus for connecting networks as set forth inclaim 1, wherein the plural addresses arranged in the table stored inthe storage means have given thereto indexes to identify the respectiveaddresses.
 3. The apparatus for connecting networks as set forth inclaim 1, wherein the first transmission means adds indexes of theaddresses, which include the first interface address changed by theaddress change means, to the address change message, and sends theaddress change message to the plural terminal units.
 4. The apparatusfor connecting networks as set forth in claim 1, wherein the firstinterface address, the terminal unit addresses, and the second interfaceaddress are private IP (Internet Protocol) addresses which can be set uparbitrarily by a user in a closed network.
 5. A system for connectingnetworks which has an apparatus for connecting networks which connects afirst network and a second network through a first interface and asecond interface, and a plurality of terminal units included in thefirst network, the apparatus for connecting networks comprising: firststorage means for storing a first table having arranged therein aplurality of addresses consisting of a first interface address and aplurality of terminal unit addresses which specify presences of thefirst interface and of the plural terminal units in the first network,and can be set up in the first interface and in the plural terminalunits, respectively; address comparison means for, in response toconnection between the second network and the apparatus for connectingnetworks after a second interface address which specifies presence ofthe second interface in the second network is set up in the secondinterface, comparing an interface address which has been set up in thefirst interface with the second interface address which is set up in thesecond interface; network suspension means for, in response to addressclash of the interface address which has been set up in the firstinterface and the second interface address which is set up in the secondinterface after comparison by the address comparison means, suspendingconnection between the second network and the apparatus for connectingnetworks; readout means for, in response to suspension of the secondnetwork from the apparatus for connecting networks by the networksuspension means, reading out addresses including a first interfaceaddress which is different from the second interface address which isset up in the second interface out of the first table stored in thefirst storage means; first address change means for changing theinterface address which has been set up in the first interface to thefirst interface address included in the addresses read out by thereadout means; first transmission means for sending an address changemessage that the interface address which has been set up in the firstinterface is changed to the first interface address by the addresschange means to the plural terminal units; first reception means forreceiving address change confirmation messages that the terminal unitaddresses of the plural terminal units are changed which are sent fromthe respective terminal units; and second transmission means for, inresponse to reception of the address change confirmation messages sentfrom the plural terminal units by the first reception means, sending anaddress change end message that the entire terminal unit addresses ofthe plural terminal units are changed to the plural terminal units, andeach of the terminal units comprising: second reception means forreceiving the address change message sent from the first transmissionmeans of the apparatus for connecting networks; second address changemeans for, in response to reception of the address change message by thesecond reception means, changing an address of the terminal unit to theterminal unit address; third transmission means for sending the addresschange confirmation message that the terminal unit address is changed bythe second address change means to the apparatus for connectingnetworks; third reception means for receiving the address change endmessage sent from the second transmission means of the apparatus forconnecting networks; second storage means for storing a second table inwhich terminal unit addresses which can be set up in the terminal unitcorrespond to the indexes, wherein the first transmission means of theapparatus for connecting networks adds indexes of the addresses, whichinclude the first interface address changed by the first address changemeans, to the address change message, and sends the address changemessage to the plural terminal units, and wherein, in response toreception of the address change message, to which the indexes are added,by the second reception means, the second address change means of theterminal unit refers to the second table stored in the second storagemeans to retrieve terminal unit addresses which correspond to theindexes added to the address change message, and changes an address ofthe terminal unit to thus retrieved terminal unit address.
 6. The systemfor connecting networks as set forth in claim 5, the terminal unitfurther comprising: fourth transmission means for, in response toreception of the address change message by the second reception means,sending a terminal unit address transmission requirement, and theapparatus for connecting networks further comprising: fourth receptionmeans for receiving the terminal unit address transmission requirementswhich are sent from the fourth reception means of the terminal units;and fifth transmission means for, in response to the terminal unitaddress transmission requirements received by the fourth receptionmeans, sending the terminal unit addresses included in the addressesread out by the readout means out of the first table stored in the firststorage means to the respective plural terminal units included in thefirst network, wherein the second address change means of the terminalunit changes an address of the terminal unit to the terminal unitaddress sent by the fifth transmission means.
 7. The system forconnecting networks as set forth in claim 5, wherein the pluraladdresses arranged in the first table stored in the first storage meansof the apparatus for connecting networks have given thereto indexes toidentify the respective addresses.
 8. The system for connecting networksas set forth in claim 5, wherein the first interface address, theterminal unit addresses, and the second interface address are private IP(Internet Protocol) addresses which can be set up arbitrarily by a userin a closed network.
 9. A method for connecting networks which connectsa first network, which includes a plurality of terminal units, and asecond network through a first interface and a second interface,comprising the steps, by the apparatus for connecting networks, of:storing a first table having arranged therein a plurality of addressesconsisting of a first interface address and a plurality of terminal unitaddresses which specify presences of the first interface and of theplural terminal units in the first network, and can be set up in thefirst interface and in the plural terminal units, respectively, in afirst storage means; in response to connection between the secondnetwork and the apparatus for connecting networks after a secondinterface address which specifies presence of the second interface inthe second network is set up in the second interface, comparing aninterface address which has been set up in the first interface with thesecond interface address which is set up in the second interface; inresponse to address clash of the interface address which has been set upin the first interface and the second interface address which is set upin the second interface after comparison in the comparison step,suspending connection between the second network and the apparatus forconnecting networks; in response to suspension of the second networkfrom the apparatus for connecting networks, reading out addressesincluding a first interface address which is different from the secondinterface address which is set up in the second interface out of thefirst table stored in the first storage means; changing the interfaceaddress which has been set up in the first interface to the firstinterface address included in the read out addresses; and sending anaddress change message that the interface address which has been set upin the first interface is changed to the first interface address to theplural terminal units, and comprising the steps, by each of the terminalunits, of: receiving the address change message sent from the apparatusfor connecting networks; in response to reception of the address changemessage, changing an address of the terminal unit to the terminal unitaddress; sending an address change confirmation message that theterminal unit address is changed to the apparatus for connectingnetworks; in response to transmission of the address change message,receiving the terminal unit address transmission requirements which aresent from the terminal units; and in response to the received terminalunit address transmission requirements, sending the terminal unitaddresses included in the addresses read out from the first table storedin the first storage means to the respective plural terminal unitsincluded in the first network, and comprising the steps, by theapparatus for connecting networks, of: receiving the address changeconfirmation messages which are sent from the respective terminal units;and in response to reception of the address change confirmation messagessent from the plural terminal units, sending an address change endmessage that the entire terminal unit addresses of the plural terminalunits are changed to the plural terminal units, and comprising the step,by each of the terminal units, of: receiving the address change endmessage sent from the apparatus for connecting networks.
 10. The methodfor connecting networks as set forth in claim 9, comprising the step, byeach of the terminal units, of: in response to reception of the addresschange message, sending a terminal unit address transmissionrequirement, wherein the terminal unit changes an address of theterminal unit to the terminal unit address sent from the apparatus forconnecting networks.
 11. The method for connecting networks as set forthin claim 9, comprising the step, by each of the terminal units, of:storing a second table in which terminal unit addresses which can be setup in the terminal unit correspond to indexes, which are given toidentify the plural respective addresses arranged in the first tablestored in the first storage means of the apparatus for connectingnetworks, in a second storage means, wherein the apparatus forconnecting networks adds indexes of the addresses, which include thechanged first interface address, to the address change message, andsends the address change message to the plural terminal units, andwherein, in response to reception of the address change message, towhich the indexes are added, the terminal unit refers to the secondtable stored in the second storage means to retrieve terminal unitaddresses which correspond to the indexes added to the address changemessage, and changes an address of the terminal unit to thus retrievedterminal unit address.